/**
 * This file is part of 1genia trampoline
 * Copyright (C) 2007 1genia (contact@1genia.com)
 *
 * This library is free software; you can redistribute it and/or modify
 * it under the terms of the GNU Lesser General Public License as
 * published by the Free Software Foundation; version 3 of the License. 
 *
 * This library is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details. 
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; see the file COPYING.TXT.  If not,
 * write to the Free Software Foundation, Inc., 51 Franklin Street,
 * Fifth Floor, Boston, MA 02110-1301, USA. 
 **/
package com.genia.toolbox.web.filter.impl;

import javax.servlet.FilterConfig;

import com.genia.toolbox.web.filter.CustomFilter;

/**
 * Default implementation of <code>CustomFilter</code>.
 */
public abstract class AbstractCustomFilter
    implements CustomFilter
{

  /**
   * the order property that define in which order the filter must be applied.
   */
  private int order = 0;



  /**
   * Called by the web container to indicate to a filter that it is being taken
   * out of service. This implementation does nothing.
   * 
   * @see javax.servlet.Filter#destroy()
   */
  public void destroy()
  {
    // Do nothing.
  }



  /**
   * Called by the web container to indicate to a filter that it is being placed
   * into service. This implementation does nothing.
   * 
   * @param config
   *          the configuration of this filter.
   * @see javax.servlet.Filter#init(javax.servlet.FilterConfig)
   */
  public void init(final FilterConfig config)
  {
    // Do nothing.
  }



  /**
   * setter for the order property.
   * 
   * @param order
   *          the order to set
   */
  public void setOrder(final int order)
  {
    this.order = order;
  }



  /**
   * getter for the order property.
   * 
   * @return the order
   */
  public int getOrder()
  {
    return order;
  }

}
